package com.jimmy.medical.base;

import org.springframework.data.repository.CrudRepository;

import java.io.Serializable;

/**
 * Crud服务接口
 */
public interface CrudService<Rep extends CrudRepository<T, ID>, T, ID extends Number> {
    <S extends T> S save(S var1);

    <S extends T> Iterable<S> save(Iterable<S> var1);

    T findOne(ID var1);

    boolean exists(ID var1);

    Iterable<T> findAll();

    long count();

    void delete(ID var1);

    void deleteByKeys(Iterable<? extends ID> keys);

    void delete(T var1);

    void delete(Iterable<? extends T> var1);

    void deleteAll();
}
